home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / macros / mathematica / tex-mma.tar_z / tex-mma / tex-mma-assemble-package < prev    next >
Text File  |  1991-04-22  |  1KB  |  38 lines

  1. #! /bin/sh
  2.  
  3. # 4/5/1991 Dan Dill dan@chem.bu.edu
  4. # This is part of TeX/Mathematica
  5.  
  6. # This script is executed as
  7. #
  8. #    $cmd document-file package-type package-file
  9. #
  10. # to assemble package-file of package-type from document-file.
  11. # This script edits the template Emacs Lisp file
  12. # $bindir/tex-mma-assemble-package.tmplt.
  13. # The edited file is written to directory $tmpdir.
  14. # It is then loaded into Emacs and executed.
  15. # See comments in $bindir/tex-mma-assemble-package.tmplt for further details.
  16. # The log of the emacs session is written to document-file.log
  17.  
  18. # Edit bindir, tmpdir (and tmpdirsed, tmpdir santized for sed)
  19. # for your system
  20. bindir=/usr8/dan/bin
  21. tmpdir=/usr8/dan/emacs/lisp
  22. tmpdirsed=\\/usr8\\/dan\\/emacs\\/lisp
  23.  
  24. cmd=tex-mma-assemble-package
  25.  
  26. if [ $# -lt 3 ]
  27. then
  28. echo $cmd package-type package-file document-file 
  29. exit 1
  30. fi
  31.  
  32. sed s/LDIR/$tmpdirsed/ $bindir/tex-mma-assemble-package.tmplt \
  33.     | sed s/TYPE/$1/ \
  34.     | sed s/FILE/$2/ \
  35.         > $tmpdir/$$.el
  36. emacs -batch $3 -l $tmpdir/$$.el -f tex-mma-assemble -kill > $2.log
  37. rm $tmpdir/$$.el
  38.